home *** CD-ROM | disk | FTP | other *** search
/ Complete Linux / Complete Linux.iso / docs / apps / circuits / spice2g6.z / spice2g6 / spice / Fortran / setprn.f < prev    next >
Encoding:
Text File  |  1989-02-03  |  3.0 KB  |  90 lines

  1.       subroutine setprn(loc)
  2.       implicit double precision (a-h,o-z)
  3. c
  4. c     this routine formats the column headers for tabular listings of
  5. c output variables.
  6. c
  7. c spice version 2g.6  sccsid=tabinf 3/15/83
  8.       common /tabinf/ ielmnt,isbckt,nsbckt,iunsat,nunsat,itemps,numtem,
  9.      1   isens,nsens,ifour,nfour,ifield,icode,idelim,icolum,insize,
  10.      2   junode,lsbkpt,numbkp,iorder,jmnode,iur,iuc,ilc,ilr,numoff,isr,
  11.      3   nmoffc,iseq,iseq1,neqn,nodevs,ndiag,iswap,iequa,macins,lvnim1,
  12.      4   lx0,lvn,lynl,lyu,lyl,lx1,lx2,lx3,lx4,lx5,lx6,lx7,ld0,ld1,ltd,
  13.      5   imynl,imvn,lcvn,nsnod,nsmat,nsval,icnod,icmat,icval,
  14.      6   loutpt,lpol,lzer,irswpf,irswpr,icswpf,icswpr,irpt,jcpt,
  15.      7   irowno,jcolno,nttbr,nttar,lvntmp
  16. c spice version 2g.6  sccsid=status 3/15/83
  17.       common /status/ omega,time,delta,delold(7),ag(7),vt,xni,egfet,
  18.      1   xmu,sfactr,mode,modedc,icalc,initf,method,iord,maxord,noncon,
  19.      2   iterno,itemno,nosolv,modac,ipiv,ivmflg,ipostp,iscrch,iofile
  20. c spice version 2g.6  sccsid=miscel 3/15/83
  21.       common /miscel/ atime,aprog(3),adate,atitle(10),defl,defw,defad,
  22.      1  defas,rstats(50),iwidth,lwidth,nopage
  23. c spice version 2g.6  sccsid=dc 3/15/83
  24.       common /dc/ tcstar(2),tcstop(2),tcincr(2),icvflg,itcelm(2),kssop,
  25.      1   kinel,kidin,kovar,kidout
  26. c spice version 2g.6  sccsid=ac 3/15/83
  27.       common /ac/ fstart,fstop,fincr,skw2,refprl,spw2,jacflg,idfreq,
  28.      1   inoise,nosprt,nosout,nosin,idist,idprt
  29. c spice version 2g.6  sccsid=tran 3/15/83
  30.       common /tran/ tstep,tstop,tstart,delmax,tdmax,forfre,jtrflg
  31. c spice version 2g.6  sccsid=outinf 3/15/83
  32.       common /outinf/ xincr,string(15),xstart,yvar(8),itab(8),itype(8),
  33.      1   ilogy(8),npoint,numout,kntr,numdgt
  34. c spice version 2g.6  sccsid=blank 3/15/83
  35.       common /blank/ value(200000)
  36.       integer nodplc(64)
  37.       complex cvalue(32)
  38.       equivalence (value(1),nodplc(1),cvalue(1))
  39. c
  40.       data ablnk, atimex, afreq / 1h , 6h  time, 6h  freq /
  41. c
  42. c  set limits depending upon the analysis mode
  43. c
  44.       if (mode-2) 10,20,30
  45.    10 xstart=tcstar(1)
  46.       xincr=tcincr(1)
  47.       npoint=icvflg
  48.       itemp=itcelm(1)
  49.       loce=nodplc(itemp+1)
  50.       asweep=value(loce)
  51.       go to 40
  52.    20 xstart=tstart
  53.       xincr=tstep
  54.       npoint=jtrflg
  55.       asweep=atimex
  56.       go to 40
  57.    30 xstart=fstart
  58.       xincr=fincr
  59.       npoint=icalc
  60.       asweep=afreq
  61. c
  62. c  construct and print the output variable names
  63. c
  64.    40 loct=loc+2
  65.       ipos=1
  66.       npos=ipos+numdgt+8
  67.       do 90 i=1,kntr
  68.       loct=loct+2
  69.       itab(i)=nodplc(loct)
  70.       itype(i)=nodplc(loct+1)
  71.       call outnam(itab(i),itype(i),string,ipos)
  72.       if (ipos.ge.npos) go to 70
  73.       do 60 j=ipos,npos
  74.       call move(string,j,ablnk,1,1)
  75.    60 continue
  76.       ipos=npos
  77.       go to 80
  78.    70 call move(string,ipos,ablnk,1,1)
  79.       ipos=ipos+1
  80.    80 npos=npos+numdgt+8
  81.    90 continue
  82.       call move(string,ipos,ablnk,1,7)
  83.       jstop=(ipos+6)/8
  84.       write (iofile,91) asweep,(string(j),j=1,jstop)
  85.    91 format(/3x,a8,5x,14a8,a4)
  86.       write (iofile,101)
  87.   101 format(1hx/1h )
  88.       return
  89.       end
  90.